<template>
  <div>
    <my-goods
      v-for="item in list"
      :key="item.id"
      :title="item.name"
      :price="item.price"
      :desc="item.desc"
    />
  </div>
</template>

<script>
// 导入组件
import MyGoods from "./components/MyGoods";
export default {
  // 注册组件
  components: {
    MyGoods,
  },
  data() {
    return {
      title: "sb",
      price: 99,
      // 服务器返回的
      list: [
        { id: 11, name: "潮汕粥", price: 99, desc: "营养美味" },
        { id: 33, name: "猪脚饭", price: 15, desc: "肥肥的" },
        { id: 39, name: "沙县小吃", price: 14, desc: "吃蒸饺和汤" },
        { id: 434, name: "自选快餐", price: 14, desc: "随便选" },
      ],
    };
  },
};
</script>

<style>
</style>